package cn.ahaiahaixx.exception;

/**
 * AppException应用程序自定义异常(需要指定code和message)
 * 
 * @author Aiden Pearce
 *
 */
public class AppException extends Exception {

	private static final long serialVersionUID = 7223333019194594123L;
	private int code = 500;
	public AppException(int code,String message) {
		super(message);
		this.code=code;
	}
	public static AppException getAppException(int code,String message) {
		return new AppException(code, message);
	}
	
	public int getCode() {
		return code;
	}

}
